package com.mineoj.service;

import com.mineoj.model.entity.CompetitionJoin;
import com.baomidou.mybatisplus.extension.service.IService;
import com.mineoj.model.entity.User;

/**
* @author 明月
* @description 针对表【competition_join(比赛参加)】的数据库操作Service
* @createDate 2025-04-20 18:59:17
*/
public interface CompetitionJoinService extends IService<CompetitionJoin> {
    /**
     * 参赛
     *
     * @param competitionId
     * @param loginUser
     * @return
     */
    int doCompetitionJoin(long competitionId, User loginUser);

    /**
     * 参赛（内部服务）
     *
     * @param userId
     * @param competitionId
     * @return
     */
    int doCompetitionJoinInner(long userId, long competitionId);

}
